<?php
	

defined('_JEXEC') or die();

class NBEventMapsControllerAuteur extends NBEventMapsController
{
	
	function __construct()
	{
		parent::__construct();
	}

	
	function view()
	{
		JRequest::setVar( 'view', 'auteur' );
		JRequest::setVar( 'layout', 'default'  );

		parent::display();
	}


	
	function save()
	{
		$post	= JRequest::get('post');
		$model = $this->getModel('auteur');

		$return=$model->store($post);
		if ($return>0) {
			$msg = JText::_( 'NBEVENTMAP_SAVED' );
		} else {
			$msg = JText::_( 'NBEVENTMAP_SAVED_ERROR' );
		}

		$link = 'index.php?option=com_nbeventmap&controller=nbeventmap&task=view';
		
		$this->setRedirect($link, $msg);
	}

	
	function cancel()
	{
		$msg = JText::_( 'Operation Cancelled' );
		$this->setRedirect( 'index.php?option=com_nbeventmap&controller=nbeventmap&task=view', $msg );
	}
}
?>
